package com.service.impl;

import com.pojo.Car;
import com.pojo.User;
import com.service.UserService;
import org.springframework.stereotype.Component;

import javax.jws.WebService;
import java.util.List;

@WebService(endpointInterface = "com.service.UserService",
        serviceName = "UserService",
        targetNamespace = "http://zhangxuUserService.com")
@Component
public class UserServiceImpl implements UserService {
    @Override
    public String sayHello() {
        return "sayHello=====" + "name";
    }

    @Override
    public User getCars() {
        User user = new User();
        List<Car> cars = user.getCars();
        Car car = new Car();
        car.setCarName("呵呵");
        car.setPrice("1000");
        cars.add(car);
        return user;
    }
}
